The technology described herein relates to data processing systems in which an accelerator, such as a graphics processing unit (GPU), a video accelerator or a digital signal processor, etc., acts as a common shared resource for a plurality of applications (such as games, productivity applications, browsers, etc.) and in particular to a method and data processing system for handling the accelerator's scheduling statistics.
In a virtualised data processing system, including multiple virtual machines, in order to provide hardware access to a virtualisation aware device, e.g. an accelerator, a hypervisor is usually used to manage the allocation of a number of input/output interfaces to the virtual machines which require access to the resources of the accelerator. In order to manage the allocation of the input/output interfaces the hypervisor needs to have access to scheduling statistics—information regarding the frequency and duration of tasks submitted to and running on the accelerator, for example, so that it can best schedule the submission of future tasks to the accelerator. Such information is particularly required by the hypervisor when there are more virtual machines wishing to submit tasks than the accelerator has capacity to manage simultaneously, e.g. owing to a hardware limit on the number of input/output interfaces. Thus access to the accelerator must be time shared by the virtual machines, and the use of the scheduling statistics helps to optimise this time sharing.
In conventional systems the scheduling statistics are requested by the hypervisor from the accelerator when they are needed, e.g. prior to the initialisation of an input/output interface for a virtual machine to connect to the accelerator. The hypervisor submits a request command to the accelerator which responds with the requested scheduling statistics. The requested types of scheduling statistics may be different each time, e.g. depending on the nature of the virtual machine requesting access to the accelerator.
The Applicants believe that there remains scope for improved methods and systems for providing scheduling information in data processing systems.